﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web.UI;

namespace VitCode.BaseDataPageCreator
{
    public class SessionObjectHelper
    {

        public static void SetSession(Page p,string key,object val)
        {
            p.Session[p.Request.RawUrl + key] = val;
        }

        public static object GetSession(Page p,string key)
        {
            string keyVal = p.Request.RawUrl + key;
            if (p.Session[keyVal] != null)
                return p.Session[keyVal];
            return null;
        }
    }
}
